<!DOCTYPE html>
<html lang="cn" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="UTF-8">
    <title>互联网村镇管理平台</title>
    <link rel="stylesheet" type="text/css" th:href="@{/css/common.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{/css/main.css}" />
</head>
<body>
    <div class="container clearfix">
        <!--/sidebar-->
        <div class="main-wrap">
            <div class="crumb-wrap">
                <div class="crumb-list">
                    <i class="icon-font">&#xe904;</i>
                    <a href="javascript:void(0);">信息管理</a>
                    <span class="crumb-step">&gt;</span>
                    <span class="crumb-name">Banner图管理</span>
                </div>
            </div>
            <div class="search-wrap">
                <div class="search-content">
                    <form th:action="@{/bannerTourist/list}" method="post" id="queryForm">
                        <table class="search-tab" style="margin-left: 10px;">
                            <tr>
                                <th width="110">Banner图名称:</th>
                                <td>
                                    <input class="common-text" placeholder="Banner图名称" name="title" th:value="${title }" type="text" />
                                </td>
                                <th width="110">Banner图描述:</th>
                                <td>
                                    <input class="common-text" placeholder="Banner图描述" name="content" th:value="${content }" type="text" />
                                </td>
                                <th width="110">Banner类型:</th>
                                <td>
                                    <select name="type" style="height: 30px; width: 150px;" onchange="javascripte:$('#queryForm').submit();">
                                        <option value="-1">全部</option>
                                        <option value="2" th:selected="${type == '2'}">首页轮播图</option>
                                        <option value="3" th:selected="${type == '3'}">体验旅游内容图</option>
                                        <option value="4" th:selected="${type == '4'}">本地特产内容图</option>
                                    </select>
                                </td>
                                <td>
                                    <input class="btn btn-primary btn2" name="sub" value="查询" type="submit">
                                </td>
                            </tr>
                        </table>
                    </form>
                </div>
            </div>
            <div class="result-wrap">
                <div class="result-title">
                    <div class="result-list">
                        <a th:href="@{/bannerTourist/addLBanner}" href=""><i class="icon-font">&#xea0a;</i>新增首页轮播图</a>
                       	<a th:href="@{/bannerTourist/addCBanner}" href=""><i class="icon-font">&#xea0a;</i>新增体验旅游内容图</a>
                       	<a th:href="@{/bannerTourist/addNBanner}" href=""><i class="icon-font">&#xea0a;</i>新增本地特产内容图</a>
                        <a id="batchDel" href="javascript:batchDeleteBanners();"><i class="icon-font">&#xe9ac;</i>批量删除</a>
                    </div>
                </div>
                <div class="result-content">
                    <table class="result-tab" width="100%">
                        <tr>
                            <th class="tc" width="5%"><input class="allChoose" onclick="javascript:shiro.form.setCheckBoxSelectToggle('bannerIdCheckBox');" type="checkbox" /></th>
                            <th width="25%">Banner图标题</th>
                            <th width="35%">Banner图描述</th>
                            <th width="25%">Banner图类型</th>
                            <th class="tc" width="10%">操作</th>
                        </tr>

                        <tr th:each="banner:${bannerInfoList}">
                            <td class="tc">
                                <input name="bannerIdCheckBox" th:value="${banner?.bannerId }" type="checkbox" />
                            </td>
                            <td th:text="${banner?.title }"></td>
                            <td th:text="${banner?.content }"></td>
                            <td th:if="${banner?.type == 2 }">首页轮播图</td>
                            <td th:if="${banner?.type == 3 }">体验旅游内容图</td>
                            <td th:if="${banner?.type == 4 }">本地特产内容图</td>
                            <td class="tc" th:if="${banner?.type == 2}">
                                <a class="link-update" th:href="@{'/bannerTourist/editLBanner/' + ${banner?.bannerId}}">修改</a>
                                <a class="link-del" th:href="'javascript:deleteBanner(\'' + ${banner?.bannerId } + '\');'">删除</a>
                            </td>
                            <td class="tc" th:if="${banner?.type !=2}">
                                <a class="link-update" th:href="@{'/bannerTourist/editCBanner/' + ${banner?.bannerId}}">修改</a>
                                <a class="link-del" th:href="'javascript:deleteBanner(\'' + ${banner?.bannerId } + '\');'">删除</a>
                            </td>
                        </tr>
                    </table>

                </div>
                <div class="list-page" th:utext="${pageHtml}">
                </div>
            </div>
        </div>
    </div>
    <div th:include="admin/common/common"></div>
    <script type="text/javascript" th:src="@{/js/web/bannerTourist/bannerTourist.js?v=1.1}"></script>
</body>
</html>